Page({
  data: {
      //banner的轮播图
      swiperArr:[
        "/images/banner/baner1.jpg",
        "/images/banner/baner2.jpg",
        "/images/banner/baner3.jpg",
        "/images/banner/baner4.jpg"],
      xArr: [
        {
          src: "/images/home/card01.jpg",
          text: '给特别的你'
        },
        {
          src: "/images/home/card02.jpg",
          text: '我想对你说'
        },
        {
          src: "/images/home/card03.jpg",
          text: '勇敢爱'
        },
        {
          src: "/images/home/card04.jpg",
          text: '一个人的精彩'
        },
        {
          src: "/images/home/card05.jpg",
          text: '萌萌哒'
        },
        {
          src: "/images/home/card06.jpg",
          text: '友谊万岁'
        },
        {
          src: "/images/home/card07.jpg",
          text: '恋人未满'
        },
        {
          src: "/images/home/card08.jpg",
          text: '生日快乐'
        }
      ],
    indicatorDots: true,
    vertical: false,
    autoplay: true,
    interval: 2000,
    duration: 500,
    // 新品展示数组
    newArr: [
      {imgSrc: "/images/home/newPro1.jpg", imgTxt: "卡布奇诺"},
      {imgSrc: "/images/home/newPro2.jpg", imgTxt: "白咖啡"},
      {imgSrc: "/images/home/newPro3.jpg", imgTxt: "摩卡咖啡"},
      {imgSrc: "/images/home/newPro4.jpg", imgTxt: "爱尔兰咖啡"},
      {imgSrc: "/images/home/newPro5.jpg", imgTxt: "甜品咖啡"},
      {imgSrc: "/images/home/newPro6.jpg", imgTxt: "意大利咖啡"},
      {imgSrc: "/images/home/newPro7.jpg", imgTxt: "拿铁咖啡"},
      {imgSrc: "/images/home/newPro8.jpg", imgTxt: "中式咖啡"}
    ]
  },
  goPage(){
    // wx.navigateTo({
    //   // 在tabbar中注册的页面就不可以使用这种方法跳转
    //   // url: '/pages/menu/menu',
    //   url:'/pages/ceshi/ceshi'
    // })

    wx.switchTab({
      // 这种方法可以跳转到tabbar中注册的页面
      url: '/pages/menu/menu',
    })
  }

  
})